package com.aoip.telemetry.telemetry.configureui.business.pipeline.handle.service;

import com.aoip.telemetry.telemetry.entity.pipeline.PipelineHandleEntity;

import java.util.List;

/**
 * @author chenbai
 * @version 1.0
 * @date 2021/11/25 10:32
 */
public interface PipelineHandleService {

    /**
     * 处理器规则列表
     *
     * @param entity 处理器规则实体
     * @return java.util.List<com.aoip.telemetry.telemetry.entity.pipeline.PipelineHandleEntity>
     * @author chenbai
     * @date 2022/2/11
     **/
    List<PipelineHandleEntity> list(PipelineHandleEntity entity);

    /**
     * @param id 处理器规则主键
     * @return com.aoip.telemetry.telemetry.entity.pipeline.PipelineHandleEntity
     * @author chenbai
     * @date 2022/2/11
     **/
    PipelineHandleEntity pipelineHandle(String id);

    /**
     * 处理器规则新增
     *
     * @param entity 处理器规则实体
     * @return int
     * @author chenbai
     * @date 2022/2/11
     **/
    int insert(PipelineHandleEntity entity);

    /**
     * 处理器规则修改
     *
     * @param entity 处理器规则实体
     * @return int
     * @author chenbai
     * @date 2022/2/11
     **/
    int update(PipelineHandleEntity entity);

    /**
     * 初始化数据到redis缓存库
     *
     * @return int
     * @author chenbai
     * @date 2022/3/8
     **/
    int initCache();
    /**
     * 处理器规则删除
     *
     * @param ids 处理器规则主键集合
     * @author chenbai
     * @date 2022/2/11
     **/
    void delete(long[] ids);

}
